home *** CD-ROM | disk | FTP | other *** search
- stop();
- showScores = function()
- {
- var _l2 = 10;
- while(_l2 > 0)
- {
- var _l3 = scoreboard_lv["name" + (page + _l2)];
- var s = scoreboard_lv["score" + (page + _l2)];
- var _l1 = this["line" + _l2 + "_mc"];
- _l1.rank_txt.text = page + _l2 + ".";
- _l1.name_txt.text = !_l3.length ? "..." : _l3.toUpperCase();
- _l1.score_txt.text = !s.length ? "..." : s.addCommas();
- _l1.rank_txt.textColor = _l1.name_txt.textColor = _l1.score_txt.textColor = !(game_so.data.playerName.length && _l3.toUpperCase() == game_so.data.playerName.toUpperCase()) ? 16777215 : 16777011;
- _l1._visible = true;
- loading_mc._visible = false;
- _l2--;
- }
- };
- page = 0;
- maxScore = 100;
- scoreboard_lv = new LoadVars();
- if(score > 0 && game_so.data.playerName.length > 0)
- {
- scoreboard_lv.score = score;
- scoreboard_lv.name = game_so.data.playerName.toLowerCase();
- }
- scoreboard_lv.game = "pacman";
- scoreboard_lv.sendAndLoad("pacman_score_text.php",scoreboard_lv,"POST");
- scoreboard_lv.onLoad = function(success)
- {
- if(success)
- {
- if(Boolean(scoreboard_lv.success))
- {
- next_btn._visible = true;
- if(scoreboard_lv.maxScore.length > 0)
- {
- maxScore = Number(scoreboard_lv.maxScore);
- }
- showScores();
- }
- else
- {
- loading_mc.errorMsg = scoreboard_lv.errorMsg.toUpperCase();
- loading_mc.gotoAndStop(2);
- }
- }
- else
- {
- loading_mc.errorMsg = "COULD NOT ACCESS SCORES.";
- loading_mc.gotoAndStop(2);
- }
- };
- score = 0;
- next_btn._visible = last_btn._visible = false;
-